<%@ page contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ include file="/WEB-INF/jsp/common/include/taglibs.jsp"%>
<script type="text/javascript">

$(document).ready(function(){
	<c:if test="${param.returnCd=='0000' }">alert('수정했습니다');</c:if>	
});

//데이터 저장
function submitData(){
	if($("#p_logo").val()!=''){
		
		$("#del_p_logo").attr("checked",true);
	}
	if($("#footer_logo").val()!=''){
		$("#del_footer_logo").attr("checked",true);
	}
	if($("#event_img").val()!=''){
		$("#del_event_img").attr("checked",true);
	}
	$("#frmData").submit();
}

//부가정보 추가
function addArray(target,type){
	var html="";
	if("1"==type){
		html="<div class='paa1'><input name='paa_types' type='hidden' value='1' />&nbsp;&nbsp;<input type='text' name='paa_descs' maxlength='50' size='20' value=''/>(은행명 계좌번호 예금주)<a href='#' onclick='$(this).parent().remove();return false;'>삭제</a></div>";
	}else if("2"==type){
		html="<div class='paa2'><input name='paa_types' type='hidden' value='2' />&nbsp;&nbsp;<input name='paa_type' type='hidden' value='2' /><input type='text' name='paa_descs' maxlength='50' size='20' value=''><a href='#' onclick='$(this).parent().remove();return false;'>삭제</a></div>";
	}else if("3"==type){
		html="<div class='paa3'><input name='paa_types' type='hidden' value='3' />&nbsp;&nbsp;<input name='paa_type' type='hidden' value='2' /><input type='text' name='paa_descs' maxlength='50' size='20' value=''><a href='#' onclick='$(this).parent().remove();return false;'>삭제</a></div>";
	}else if("4"==type){
		html="<div class='paa4'><input name='paa_types' type='hidden' value='4' />&nbsp;&nbsp;<input name='paa_type' type='hidden' value='2' /><input type='text' name='paa_descs' maxlength='50' size='20' value=''><a href='#' onclick='$(this).parent().remove();return false;'>삭제</a></div>";
	}
	$("."+target+":last").after(html);
}
</script>

<%@ include file="/WEB-INF/jsp/pmgr/pe/ti/page_top.jsp"%>

<!-- petc0105T -->

<form action="<c:if test="${empty group }">./petc0103T.do</c:if><c:if test="${!empty group }">./petc0105T.do</c:if>" id="frmData" name="frmData" enctype="multipart/form-data" method="post">
<input name="p_id" value="${map.p_id }" type="hidden"/>
<input name="pg_no" value="${group.pg_no }" type="hidden"/>
사이트그룹
	<table width="700" border="0" cellspacing="1" cellpadding="2"
		class="class_admin_table">
		<tr>
			<td height="25" class="class_admin_table_head" width="100"
				align="center">그룹명</td>
			<td height="25" class="class_admin_table_blank" >&nbsp;
				<input name="group_nm" value="${group.group_nm }" type="text"/>
			</td>
		</tr>
		<tr>
			<td height="25" class="class_admin_table_head" width="100"
				align="center">배경이미지</td>
			<td height="25" class="class_admin_table_blank" >&nbsp;&nbsp;<input
				type="file" name="back_img" id="back_img" style="width: 70%;" class="gray">
				<c:if test="${!empty group.back_img && ''!= group.back_img}"><br/>
				<a href="${group.back_img }" target="_blank"><img src="${group.back_img }" width="100" /></a>
				<br/>
				<label><input name="del_yn" id="del_yn" value="${group.back_img }" type="checkbox" /> 이미지 삭제(${group.back_img })</label>
				</c:if>
			</td>
		</tr>
	</table>
	<br>
	<table width="700" border="0" cellspacing="1" cellpadding="2"
		class="class_admin_table_nocolor">
		<tr>
			<td height="25" align="center">
				<input type="button" onclick="submitData();"  value="정 보 수 정">
				<input type="button" onclick="history.back();"  value="돌아가기">
			</td>
		</tr>
	</table>
	
</form>


</body>
</html>
